package com.qijian.maindata.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.qijian.maindata.domain.LineChange;
import com.qijian.maindata.domain.LineChangeDetail;
import com.qijian.maindata.domain.query.ProcessPerformanceQuery;
import com.qijian.maindata.domain.vo.LineChangeVo;
import com.qijian.maindata.domain.vo.ProcessLineChangeVo;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.Collection;
import java.util.List;

/**
 * 工艺变更Mapper接口
 *
 * @author qijian
 * @date 2022-02-23
 */
public interface LineChangeMapper extends BaseMapper<LineChange> {

    @Select("select count(0) from main_line_change WHERE create_time >= CURRENT_DATE ")
    int countCurrentDateWithDel();

    LineChangeVo selectVoById(Long changeId);

    List<LineChangeDetail> selectDetailsById(Long changeId);

    List<ProcessLineChangeVo> selectLineChangeList(@Param("query") ProcessPerformanceQuery query);


}
